package com.softeem.work.w6;

public class Car extends Auto{
    //空调
    private boolean kt;
    //CD
    private boolean cd;

    public Car() {
        super();
    }
    public Car(int tyreNum, String color, double weight, double speed, boolean kt, boolean cd) {
        super(tyreNum, color, weight, speed);
        this.kt = kt;
        this.cd = cd;
    }

    public boolean isKt() {
        return kt;
    }

    public void setKt(boolean kt) {
        this.kt = kt;
    }

    public boolean isCd() {
        return cd;
    }

    public void setCd(boolean cd) {
        this.cd = cd;
    }

    //加速
    public void speedUp(){
        super.setSpeed(super.getSpeed()+100);
    }
    //减速
    public void speedDown(){
        super.setSpeed(super.getSpeed()-100);
    }

}
